package com.qige.homework.test;

public class Circle extends Graphic {
    public double radius;
    public Circle(double radius)
    {
        this.radius = radius;
    }
    public double getArea()
    {
        return Math.PI * radius * radius;
    }
    public double getPerimeter()
    {
        return 2 * Math.PI * radius;
    }

    @Override
    public String getInfo() {
        return  "半径" + radius + "," +super.getInfo();
    }
}